<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/webpage/include/taglib.jsp"%>
<html>
<head>
	<title>用户信息管理</title>
	<meta name="decorator" content="ani"/>
	<script type="text/javascript">

		$(document).ready(function() {
			jp.ajaxForm("#inputForm",function(data){
				if(data.success){
				    jp.success(data.msg);
					jp.go("${ctx}/member/member");
				}else{
				    jp.error(data.msg);
				    $("#inputForm").find("button:submit").button("reset");
				}
			});

		});
	</script>
	<script src="${ctxStatic}/plugin/jquery-1.8.3.min.js"></script><!-- jQuery is required -->
	<script src="${ctxStatic}/plugin/city-picker/js/city-picker.data.js"></script>
	<script src="${ctxStatic}/plugin/city-picker/js/city-picker.js"></script>
	<link rel="stylesheet" type="text/css" href="${ctxStatic}/plugin/city-picker/css/city-picker.css"/>
</head>
<body>
<div class="wrapper wrapper-content">				
<div class="row">
	<div class="col-md-12">
	<div class="panel panel-primary">
		<div class="panel-heading">
			<h3 class="panel-title"> 
				<a class="panelButton" href="${ctx}/member/member"><i class="ti-angle-left"></i> 返回</a>
			</h3>
		</div>
		<div class="panel-body">
		<form:form id="inputForm" modelAttribute="member" action="${ctx}/member/member/save" method="post" class="form-horizontal">
		<form:hidden path="id"/>
				<div class="form-group">
					<label class="col-sm-2 control-label"><font color="red">*</font>登录名：</label>
					<div class="col-sm-10">
						<form:input path="loginName" htmlEscape="false"    class="form-control required"/>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">登录密码（不修改则留空）：</label>
					<div class="col-sm-10">
						<form:input path="pwd" htmlEscape="false"    class="form-control  "/>
					</div>
				</div>
				<%--<div class="form-group">--%>
					<%--<label class="col-sm-2 control-label">交易密码（不修改则留空）：</label>--%>
					<%--<div class="col-sm-10">--%>
						<%--<form:input path="jypwd" htmlEscape="false"    class="form-control  "/>--%>
					<%--</div>--%>
				<%--</div>--%>
				<div class="form-group">
					<label class="col-sm-2 control-label"><font color="red">*</font>手机号：</label>
					<div class="col-sm-10">
						<form:input path="mobile" htmlEscape="false"    class="form-control required"/>
					</div>
				</div>
				<%--<div class="form-group">--%>
					<%--<label class="col-sm-2 control-label">昵称：</label>--%>
					<%--<div class="col-sm-10">--%>
						<%--<form:input path="nickName" htmlEscape="false"   class="form-control "/>--%>
					<%--</div>--%>
				<%--</div>--%>
				<%-- <div class="form-group">
					<label class="col-sm-2 control-label">头像：</label>
					<div class="col-sm-10">
						<sys:fileUpload path="img"  value="${member.img}" type="file" uploadPath="/member/member"/>
					</div>
				</div> --%>
				<div class="form-group">
					<label class="col-sm-2 control-label">邀请码：</label>
					<div class="col-sm-10">
						<form:input path="tgcode" htmlEscape="false"  disabled="true" class="form-control "/>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">直推人数：</label>
					<div class="col-sm-10">
						<form:input path="num" htmlEscape="false"   class="form-control required"/>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">用户等级：</label>
					<div class="col-sm-10">
						<form:select path="usertype" class="form-control required">
							<form:option value="" label=""/>
							<form:options items="${fns:getDictList('user_type')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
						</form:select>
					</div>
				</div>
				
				<div class="form-group">
					<label class="col-sm-2 control-label">姓名：</label>
					<div class="col-sm-10">
						<form:input path="name" htmlEscape="false"    class="form-control "/>
					</div>
				</div>
				<%--<div class="form-group">--%>
					<%--<label class="col-sm-2 control-label">身份证号：</label>--%>
					<%--<div class="col-sm-10">--%>
						<%--<form:input path="idcode" htmlEscape="false"    class="form-control "/>--%>
					<%--</div>--%>
				<%--</div>--%>
				<div class="form-group">
					<label class="col-sm-2 control-label">是否服务中心：</label>
					<div class="col-sm-10">
						<form:select path="isService" class="form-control ">
							<form:option value="" label=""/>
							<form:options items="${fns:getDictList('yes_no')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
						</form:select>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">地区：</label>
					<div class="col-sm-10" style="position: relative;">
						<form:input path="regionPlace" htmlEscape="false"  data-toggle="city-picker"  class="form-control "/>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">是否积分中心：</label>
					<div class="col-sm-10">
						<form:select path="isIntegral" class="form-control ">
							<form:option value="" label=""/>
							<form:options items="${fns:getDictList('yes_no')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
						</form:select>
					</div>
				</div>
				<div class="form-group">
					<label class="col-sm-2 control-label">是否可提现：</label>
					<div class="col-sm-10">
						<form:select path="isCollection" class="form-control ">
							<form:option value="" label=""/>
							<form:options items="${fns:getDictList('yes_no')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
						</form:select>
					</div>
				</div>
				<%--<div class="form-group">--%>
					<%--<label class="col-sm-2 control-label"><font color="red">*</font>限制抢购订单数量：</label>--%>
					<%--<div class="col-sm-10">--%>
						<%--<form:input path="amount" htmlEscape="false"    class="form-control isDigits isIntGteZero"/>--%>
					<%--</div>--%>
				<%--</div>--%>
				
				<%-- <div class="form-group">
					<label class="col-sm-2 control-label">上级用户：</label>
					<div class="col-sm-10">
						<sys:gridselect url="${ctx}/member/member/data" id="p" name="p.id" value="${member.p.id}" labelName="p.loginName" labelValue="${member.p.loginName}"
							 title="选择上级用户" cssClass="form-control " fieldLabels="登录名|姓名" fieldKeys="loginName|name" searchLabels="登录名|姓名" searchKeys="loginName|name" ></sys:gridselect>
					</div>
				</div> --%>
		<c:if test="${mode == 'add' || mode=='edit'}">
				<div class="col-lg-3"></div>
		        <div class="col-lg-6">
		             <div class="form-group text-center">
		                 <div>
		                     <button class="btn btn-primary btn-block btn-lg btn-parsley" data-loading-text="正在提交...">提 交</button>
		                 </div>
		             </div>
		        </div>
		</c:if>
		</form:form>
		</div>				
	</div>
	</div>
</div>
</div>
</body>
</html>